/*
 * PracticeFactory.cpp
 *
 *  Created on: Mar 6, 2013
 *      Author: loadar
 */

#include "PracticeFactory.h"
#include "hello/HelloPractice.h"
#include "staticmember/StaticPractice.h"

PracticeFactory::PracticeFactory()
{

}

PracticeFactory::~PracticeFactory()
{

}

IPractice* PracticeFactory::newPracticeInstance(std::string practiceName)
{
	IPractice* practice = NULL;

	if (practiceName == "HelloPractice")
	{
		practice = new hello::HelloPractice();
	}
	else if (practiceName == "StaticPractice")
	{
		practice = new staticmember::StaticPractice();
	}
	else
		practice = NULL;

	return practice;
}
